const mongoose = require('mongoose')
const Schema = mongoose.Schema

let linkSchema = new Schema(
  {
    sitename: {
      type: String,
      required: true
    },
    site: {
      type: String,
      required: true
    },
    avatar: {
      type: String,
      required: true
    },
    introduction: {
      type: String,
      default: 'nothing'
    },
    // 状态：0未发布 1已发布
    status: {
      type: Number,
      default: 0
    }
  },
  {
    versionKey:false
  }
)

module.exports = mongoose.model("link", linkSchema)